3.86 \(\int \frac {(a+a \sin (e+f x)) (A+B \sin (e+f x))}{(c-c \sin (e+f x))^{3/2}} \, dx\)

Optimal. Leaf size=115 \[ -\frac {a (A+5 B) \tanh ^{-1}\left (\frac {\sqrt {c} \cos (e+f x)}{\sqrt {2} \sqrt {c-c \sin (e+f x)}}\right )}{\sqrt {2} c^{3/2} f}+\frac {a (A+B) \cos (e+f x)}{f (c-c \sin (e+f x))^{3/2}}+\frac {2 a B \cos (e+f x)}{c f \sqrt {c-c \sin (e+f x)}} \]

[Out]

a*(A+B)*cos(f*x+e)/f/(c-c*sin(f*x+e))^(3/2)-1/2*a*(A+5*B)*arctanh(1/2*cos(f*x+e)*c^(1/2)*2^(1/2)/(c-c*sin(f*x+
e))^(1/2))/c^(3/2)/f*2^(1/2)+2*a*B*cos(f*x+e)/c/f/(c-c*sin(f*x+e))^(1/2)

________________________________________________________________________________________

Rubi [A]  time = 0.32, antiderivative size = 115, normalized size of antiderivative = 1.00, number of steps used = 5, number of rules used = 5, integrand size = 36, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.139, Rules used = {2967, 2857, 2751, 2649, 206} \[ -\frac {a (A+5 B) \tanh ^{-1}\left (\frac {\sqrt {c} \cos (e+f x)}{\sqrt {2} \sqrt {c-c \sin (e+f x)}}\right )}{\sqrt {2} c^{3/2} f}+\frac {a (A+B) \cos (e+f x)}{f (c-c \sin (e+f x))^{3/2}}+\frac {2 a B \cos (e+f x)}{c f \sqrt {c-c \sin (e+f x)}} \]

Antiderivative was successfully verified.

[In]

Int[((a + a*Sin[e + f*x])*(A + B*Sin[e + f*x]))/(c - c*Sin[e + f*x])^(3/2),x]

[Out]

-((a*(A + 5*B)*ArcTanh[(Sqrt[c]*Cos[e + f*x])/(Sqrt[2]*Sqrt[c - c*Sin[e + f*x]])])/(Sqrt[2]*c^(3/2)*f)) + (a*(
A + B)*Cos[e + f*x])/(f*(c - c*Sin[e + f*x])^(3/2)) + (2*a*B*Cos[e + f*x])/(c*f*Sqrt[c - c*Sin[e + f*x]])

Rule 206

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1*ArcTanh[(Rt[-b, 2]*x)/Rt[a, 2]])/(Rt[a, 2]*Rt[-b, 2]), x]
 /; FreeQ[{a, b}, x] && NegQ[a/b] && (GtQ[a, 0] || LtQ[b, 0])

Rule 2649

Int[1/Sqrt[(a_) + (b_.)*sin[(c_.) + (d_.)*(x_)]], x_Symbol] :> Dist[-2/d, Subst[Int[1/(2*a - x^2), x], x, (b*C
os[c + d*x])/Sqrt[a + b*Sin[c + d*x]]], x] /; FreeQ[{a, b, c, d}, x] && EqQ[a^2 - b^2, 0]

Rule 2751

Int[((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_)*((c_.) + (d_.)*sin[(e_.) + (f_.)*(x_)]), x_Symbol] :> -Simp[(d
*Cos[e + f*x]*(a + b*Sin[e + f*x])^m)/(f*(m + 1)), x] + Dist[(a*d*m + b*c*(m + 1))/(b*(m + 1)), Int[(a + b*Sin
[e + f*x])^m, x], x] /; FreeQ[{a, b, c, d, e, f, m}, x] && NeQ[b*c - a*d, 0] && EqQ[a^2 - b^2, 0] &&  !LtQ[m,
-2^(-1)]

Rule 2857

Int[cos[(e_.) + (f_.)*(x_)]^2*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_)*((c_.) + (d_.)*sin[(e_.) + (f_.)*(x_
)]), x_Symbol] :> Simp[(2*(b*c - a*d)*Cos[e + f*x]*(a + b*Sin[e + f*x])^(m + 1))/(b^2*f*(2*m + 3)), x] + Dist[
1/(b^3*(2*m + 3)), Int[(a + b*Sin[e + f*x])^(m + 2)*(b*c + 2*a*d*(m + 1) - b*d*(2*m + 3)*Sin[e + f*x]), x], x]
 /; FreeQ[{a, b, c, d, e, f}, x] && EqQ[a^2 - b^2, 0] && LtQ[m, -3/2]

Rule 2967

Int[((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_.)*((A_.) + (B_.)*sin[(e_.) + (f_.)*(x_)])*((c_) + (d_.)*sin[(e_
.) + (f_.)*(x_)])^(n_.), x_Symbol] :> Dist[a^m*c^m, Int[Cos[e + f*x]^(2*m)*(c + d*Sin[e + f*x])^(n - m)*(A + B
*Sin[e + f*x]), x], x] /; FreeQ[{a, b, c, d, e, f, A, B, n}, x] && EqQ[b*c + a*d, 0] && EqQ[a^2 - b^2, 0] && I
ntegerQ[m] &&  !(IntegerQ[n] && ((LtQ[m, 0] && GtQ[n, 0]) || LtQ[0, n, m] || LtQ[m, n, 0]))

Rubi steps

\begin {align*} \int \frac {(a+a \sin (e+f x)) (A+B \sin (e+f x))}{(c-c \sin (e+f x))^{3/2}} \, dx &=(a c) \int \frac {\cos ^2(e+f x) (A+B \sin (e+f x))}{(c-c \sin (e+f x))^{5/2}} \, dx\\ &=\frac {a (A+B) \cos (e+f x)}{f (c-c \sin (e+f x))^{3/2}}+\frac {a \int \frac {-A c-3 B c-2 B c \sin (e+f x)}{\sqrt {c-c \sin (e+f x)}} \, dx}{2 c^2}\\ &=\frac {a (A+B) \cos (e+f x)}{f (c-c \sin (e+f x))^{3/2}}+\frac {2 a B \cos (e+f x)}{c f \sqrt {c-c \sin (e+f x)}}-\frac {(a (A+5 B)) \int \frac {1}{\sqrt {c-c \sin (e+f x)}} \, dx}{2 c}\\ &=\frac {a (A+B) \cos (e+f x)}{f (c-c \sin (e+f x))^{3/2}}+\frac {2 a B \cos (e+f x)}{c f \sqrt {c-c \sin (e+f x)}}+\frac {(a (A+5 B)) \operatorname {Subst}\left (\int \frac {1}{2 c-x^2} \, dx,x,-\frac {c \cos (e+f x)}{\sqrt {c-c \sin (e+f x)}}\right )}{c f}\\ &=-\frac {a (A+5 B) \tanh ^{-1}\left (\frac {\sqrt {c} \cos (e+f x)}{\sqrt {2} \sqrt {c-c \sin (e+f x)}}\right )}{\sqrt {2} c^{3/2} f}+\frac {a (A+B) \cos (e+f x)}{f (c-c \sin (e+f x))^{3/2}}+\frac {2 a B \cos (e+f x)}{c f \sqrt {c-c \sin (e+f x)}}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 1.61, size = 157, normalized size = 1.37 \[ \frac {a \sec (e+f x) \left (2 \sqrt {c} \left (\sin \left (\frac {1}{2} (e+f x)\right )+\cos \left (\frac {1}{2} (e+f x)\right )\right )^2 (A-2 B \sin (e+f x)+3 B)+\sqrt {2} (A+5 B) \sqrt {-c (\sin (e+f x)+1)} \left (\cos \left (\frac {1}{2} (e+f x)\right )-\sin \left (\frac {1}{2} (e+f x)\right )\right )^2 \tan ^{-1}\left (\frac {\sqrt {-c (\sin (e+f x)+1)}}{\sqrt {2} \sqrt {c}}\right )\right )}{2 c^{3/2} f \sqrt {c-c \sin (e+f x)}} \]

Antiderivative was successfully verified.

[In]

Integrate[((a + a*Sin[e + f*x])*(A + B*Sin[e + f*x]))/(c - c*Sin[e + f*x])^(3/2),x]

[Out]

(a*Sec[e + f*x]*(Sqrt[2]*(A + 5*B)*ArcTan[Sqrt[-(c*(1 + Sin[e + f*x]))]/(Sqrt[2]*Sqrt[c])]*(Cos[(e + f*x)/2] -
 Sin[(e + f*x)/2])^2*Sqrt[-(c*(1 + Sin[e + f*x]))] + 2*Sqrt[c]*(Cos[(e + f*x)/2] + Sin[(e + f*x)/2])^2*(A + 3*
B - 2*B*Sin[e + f*x])))/(2*c^(3/2)*f*Sqrt[c - c*Sin[e + f*x]])

________________________________________________________________________________________

fricas [B]  time = 0.45, size = 318, normalized size = 2.77 \[ \frac {\frac {\sqrt {2} {\left ({\left (A + 5 \, B\right )} a c \cos \left (f x + e\right )^{2} - {\left (A + 5 \, B\right )} a c \cos \left (f x + e\right ) - 2 \, {\left (A + 5 \, B\right )} a c + {\left ({\left (A + 5 \, B\right )} a c \cos \left (f x + e\right ) + 2 \, {\left (A + 5 \, B\right )} a c\right )} \sin \left (f x + e\right )\right )} \log \left (-\frac {\cos \left (f x + e\right )^{2} + {\left (\cos \left (f x + e\right ) - 2\right )} \sin \left (f x + e\right ) - \frac {2 \, \sqrt {2} \sqrt {-c \sin \left (f x + e\right ) + c} {\left (\cos \left (f x + e\right ) + \sin \left (f x + e\right ) + 1\right )}}{\sqrt {c}} + 3 \, \cos \left (f x + e\right ) + 2}{\cos \left (f x + e\right )^{2} + {\left (\cos \left (f x + e\right ) + 2\right )} \sin \left (f x + e\right ) - \cos \left (f x + e\right ) - 2}\right )}{\sqrt {c}} - 4 \, {\left (2 \, B a \cos \left (f x + e\right )^{2} + {\left (A + 3 \, B\right )} a \cos \left (f x + e\right ) + {\left (A + B\right )} a - {\left (2 \, B a \cos \left (f x + e\right ) - {\left (A + B\right )} a\right )} \sin \left (f x + e\right )\right )} \sqrt {-c \sin \left (f x + e\right ) + c}}{4 \, {\left (c^{2} f \cos \left (f x + e\right )^{2} - c^{2} f \cos \left (f x + e\right ) - 2 \, c^{2} f + {\left (c^{2} f \cos \left (f x + e\right ) + 2 \, c^{2} f\right )} \sin \left (f x + e\right )\right )}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*sin(f*x+e))*(A+B*sin(f*x+e))/(c-c*sin(f*x+e))^(3/2),x, algorithm="fricas")

[Out]

1/4*(sqrt(2)*((A + 5*B)*a*c*cos(f*x + e)^2 - (A + 5*B)*a*c*cos(f*x + e) - 2*(A + 5*B)*a*c + ((A + 5*B)*a*c*cos
(f*x + e) + 2*(A + 5*B)*a*c)*sin(f*x + e))*log(-(cos(f*x + e)^2 + (cos(f*x + e) - 2)*sin(f*x + e) - 2*sqrt(2)*
sqrt(-c*sin(f*x + e) + c)*(cos(f*x + e) + sin(f*x + e) + 1)/sqrt(c) + 3*cos(f*x + e) + 2)/(cos(f*x + e)^2 + (c
os(f*x + e) + 2)*sin(f*x + e) - cos(f*x + e) - 2))/sqrt(c) - 4*(2*B*a*cos(f*x + e)^2 + (A + 3*B)*a*cos(f*x + e
) + (A + B)*a - (2*B*a*cos(f*x + e) - (A + B)*a)*sin(f*x + e))*sqrt(-c*sin(f*x + e) + c))/(c^2*f*cos(f*x + e)^
2 - c^2*f*cos(f*x + e) - 2*c^2*f + (c^2*f*cos(f*x + e) + 2*c^2*f)*sin(f*x + e))

________________________________________________________________________________________

giac [F(-2)]  time = 0.00, size = 0, normalized size = 0.00 \[ \text {Exception raised: NotImplementedError} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*sin(f*x+e))*(A+B*sin(f*x+e))/(c-c*sin(f*x+e))^(3/2),x, algorithm="giac")

[Out]

Exception raised: NotImplementedError >> Unable to parse Giac output: Unable to check sign: (4*pi/x/2)>(-4*pi/
x/2)Unable to check sign: (4*pi/x/2)>(-4*pi/x/2)Unable to check sign: (4*pi/x/2)>(-4*pi/x/2)Unable to check si
gn: (4*pi/x/2)>(-4*pi/x/2)2/f*(2*sqrt(c*tan((f*x+exp(1))/2)^2+c)*(-1/2*B*a/c/sign(tan((f*x+exp(1))/2)-1)-1/2*B
*a*tan((f*x+exp(1))/2)/c/sign(tan((f*x+exp(1))/2)-1))/(c*tan((f*x+exp(1))/2)^2+c)+2*(1/2*(-3*A*a*(-sqrt(c)*tan
((f*x+exp(1))/2)+sqrt(c*tan((f*x+exp(1))/2)^2+c))^3-3*B*a*(-sqrt(c)*tan((f*x+exp(1))/2)+sqrt(c*tan((f*x+exp(1)
)/2)^2+c))^3+A*a*c*(-sqrt(c)*tan((f*x+exp(1))/2)+sqrt(c*tan((f*x+exp(1))/2)^2+c))-A*a*sqrt(c)*(-sqrt(c)*tan((f
*x+exp(1))/2)+sqrt(c*tan((f*x+exp(1))/2)^2+c))^2+B*a*c*(-sqrt(c)*tan((f*x+exp(1))/2)+sqrt(c*tan((f*x+exp(1))/2
)^2+c))-B*a*sqrt(c)*(-sqrt(c)*tan((f*x+exp(1))/2)+sqrt(c*tan((f*x+exp(1))/2)^2+c))^2-A*a*sqrt(c)*c-B*a*sqrt(c)
*c)/(-(-sqrt(c)*tan((f*x+exp(1))/2)+sqrt(c*tan((f*x+exp(1))/2)^2+c))^2-2*sqrt(c)*(-sqrt(c)*tan((f*x+exp(1))/2)
+sqrt(c*tan((f*x+exp(1))/2)^2+c))+c)^2/c/sign(tan((f*x+exp(1))/2)-1)+1/2*(-A*a-5*B*a)*atan((-sqrt(c)*tan((f*x+
exp(1))/2)+sqrt(c)+sqrt(c*tan((f*x+exp(1))/2)^2+c))/sqrt(2)/sqrt(-c))/sqrt(2)/sqrt(-c)/c/sign(tan((f*x+exp(1))
/2)-1)))

________________________________________________________________________________________

maple [B]  time = 1.24, size = 227, normalized size = 1.97 \[ \frac {a \left (A \sqrt {2}\, \arctanh \left (\frac {\sqrt {c \left (1+\sin \left (f x +e \right )\right )}\, \sqrt {2}}{2 \sqrt {c}}\right ) \sin \left (f x +e \right ) c +5 B \sqrt {2}\, \arctanh \left (\frac {\sqrt {c \left (1+\sin \left (f x +e \right )\right )}\, \sqrt {2}}{2 \sqrt {c}}\right ) \sin \left (f x +e \right ) c -A \sqrt {2}\, \arctanh \left (\frac {\sqrt {c \left (1+\sin \left (f x +e \right )\right )}\, \sqrt {2}}{2 \sqrt {c}}\right ) c -4 \sqrt {c \left (1+\sin \left (f x +e \right )\right )}\, \sqrt {c}\, B \sin \left (f x +e \right )-5 B \sqrt {2}\, \arctanh \left (\frac {\sqrt {c \left (1+\sin \left (f x +e \right )\right )}\, \sqrt {2}}{2 \sqrt {c}}\right ) c +2 \sqrt {c \left (1+\sin \left (f x +e \right )\right )}\, \sqrt {c}\, A +6 \sqrt {c \left (1+\sin \left (f x +e \right )\right )}\, \sqrt {c}\, B \right ) \sqrt {c \left (1+\sin \left (f x +e \right )\right )}}{2 c^{\frac {5}{2}} \cos \left (f x +e \right ) \sqrt {c -c \sin \left (f x +e \right )}\, f} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a+a*sin(f*x+e))*(A+B*sin(f*x+e))/(c-c*sin(f*x+e))^(3/2),x)

[Out]

1/2*a/c^(5/2)*(A*2^(1/2)*arctanh(1/2*(c*(1+sin(f*x+e)))^(1/2)*2^(1/2)/c^(1/2))*sin(f*x+e)*c+5*B*2^(1/2)*arctan
h(1/2*(c*(1+sin(f*x+e)))^(1/2)*2^(1/2)/c^(1/2))*sin(f*x+e)*c-A*2^(1/2)*arctanh(1/2*(c*(1+sin(f*x+e)))^(1/2)*2^
(1/2)/c^(1/2))*c-4*(c*(1+sin(f*x+e)))^(1/2)*c^(1/2)*B*sin(f*x+e)-5*B*2^(1/2)*arctanh(1/2*(c*(1+sin(f*x+e)))^(1
/2)*2^(1/2)/c^(1/2))*c+2*(c*(1+sin(f*x+e)))^(1/2)*c^(1/2)*A+6*(c*(1+sin(f*x+e)))^(1/2)*c^(1/2)*B)*(c*(1+sin(f*
x+e)))^(1/2)/cos(f*x+e)/(c-c*sin(f*x+e))^(1/2)/f

________________________________________________________________________________________

maxima [F]  time = 0.00, size = 0, normalized size = 0.00 \[ \int \frac {{\left (B \sin \left (f x + e\right ) + A\right )} {\left (a \sin \left (f x + e\right ) + a\right )}}{{\left (-c \sin \left (f x + e\right ) + c\right )}^{\frac {3}{2}}}\,{d x} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*sin(f*x+e))*(A+B*sin(f*x+e))/(c-c*sin(f*x+e))^(3/2),x, algorithm="maxima")

[Out]

integrate((B*sin(f*x + e) + A)*(a*sin(f*x + e) + a)/(-c*sin(f*x + e) + c)^(3/2), x)

________________________________________________________________________________________

mupad [F]  time = 0.00, size = -1, normalized size = -0.01 \[ \int \frac {\left (A+B\,\sin \left (e+f\,x\right )\right )\,\left (a+a\,\sin \left (e+f\,x\right )\right )}{{\left (c-c\,\sin \left (e+f\,x\right )\right )}^{3/2}} \,d x \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(((A + B*sin(e + f*x))*(a + a*sin(e + f*x)))/(c - c*sin(e + f*x))^(3/2),x)

[Out]

int(((A + B*sin(e + f*x))*(a + a*sin(e + f*x)))/(c - c*sin(e + f*x))^(3/2), x)

________________________________________________________________________________________

sympy [F]  time = 0.00, size = 0, normalized size = 0.00 \[ a \left (\int \frac {A}{- c \sqrt {- c \sin {\left (e + f x \right )} + c} \sin {\left (e + f x \right )} + c \sqrt {- c \sin {\left (e + f x \right )} + c}}\, dx + \int \frac {A \sin {\left (e + f x \right )}}{- c \sqrt {- c \sin {\left (e + f x \right )} + c} \sin {\left (e + f x \right )} + c \sqrt {- c \sin {\left (e + f x \right )} + c}}\, dx + \int \frac {B \sin {\left (e + f x \right )}}{- c \sqrt {- c \sin {\left (e + f x \right )} + c} \sin {\left (e + f x \right )} + c \sqrt {- c \sin {\left (e + f x \right )} + c}}\, dx + \int \frac {B \sin ^{2}{\left (e + f x \right )}}{- c \sqrt {- c \sin {\left (e + f x \right )} + c} \sin {\left (e + f x \right )} + c \sqrt {- c \sin {\left (e + f x \right )} + c}}\, dx\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*sin(f*x+e))*(A+B*sin(f*x+e))/(c-c*sin(f*x+e))**(3/2),x)

[Out]

a*(Integral(A/(-c*sqrt(-c*sin(e + f*x) + c)*sin(e + f*x) + c*sqrt(-c*sin(e + f*x) + c)), x) + Integral(A*sin(e
 + f*x)/(-c*sqrt(-c*sin(e + f*x) + c)*sin(e + f*x) + c*sqrt(-c*sin(e + f*x) + c)), x) + Integral(B*sin(e + f*x
)/(-c*sqrt(-c*sin(e + f*x) + c)*sin(e + f*x) + c*sqrt(-c*sin(e + f*x) + c)), x) + Integral(B*sin(e + f*x)**2/(
-c*sqrt(-c*sin(e + f*x) + c)*sin(e + f*x) + c*sqrt(-c*sin(e + f*x) + c)), x))

________________________________________________________________________________________